export const formatExcelTime = (time: number | string, format = '-') => {
  if (typeof time === 'string') {
    return time;
  }
    
  time = +time;
  
  let milliSec = 0;

  if (time > 60) {
    milliSec = (time - 25569) * 60 * 60 * 24 * 1000;
  } else {
    milliSec = (time - 25568) * 60 * 60 * 24 * 1000;
  }

  let date = new Date(milliSec);

  let yy = date.getFullYear();

  let mm = date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1;
  let dd = date.getDate() < 10 ? '0' + date.getDate() : date.getDate();

  return `${yy}${format}${mm}${format}${dd}`;
}